package com.tempjob.common.businesss.mongo.entity;

import com.anwen.mongo.annotation.ID;
import com.anwen.mongo.annotation.collection.CollectionField;
import com.anwen.mongo.annotation.collection.CollectionName;
import com.anwen.mongo.enums.FieldFill;
import com.anwen.mongo.enums.IdTypeEnum;
import com.mongodb.client.model.geojson.Point;
import com.tempjob.common.model.WorkDayModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.data.annotation.Version;

import java.util.Date;
import java.util.List;

/**
 * @author hui
 * @Date 2024/11/4 15:58
 **/

@CollectionName(value = "special_job_info")
@Data
public class SpecialJobInfo {

    @ID(type = IdTypeEnum.OBJECT_ID)
    @CollectionField("_id")
    @ApiModelProperty("id")
    private String id;

    @CollectionField("job_status")
    @ApiModelProperty("工作状态:0未提交1待审核2审核通过3审核不通过")
    private Integer jobStatus;

    @CollectionField("job_type")
    @ApiModelProperty("工作类型:1零工2正式工")
    private Integer jobType;

    @CollectionField("job_category")
    @ApiModelProperty("工作分类")
    private String jobCategory;

    @CollectionField("publish_user_name")
    @ApiModelProperty("发布人")
    private String publishUserName;

    @ApiModelProperty("工作时间")
    @CollectionField("work_day_list")
    private List<WorkDayModel> workDayList;

    @ApiModelProperty("记薪单位:1.元/月,2.元/天,3.元/小时")
    @CollectionField("salary_type")
    private Integer salaryType;

    @ApiModelProperty("薪水")
    private Integer salary;

    @CollectionField("job_title")
    @ApiModelProperty("标题")
    private String jobTitle;

    @CollectionField("job_content")
    @ApiModelProperty("工作说明")
    private String jobContent;

    @CollectionField("desc_images")
    @ApiModelProperty("介绍图片")
    private List<String> descImages;

    @CollectionField("treatment_tags")
    @ApiModelProperty("待遇标签,提供住宿、无须经验等")
    private List<String> treatmentTags;

    @ApiModelProperty("结算方式:1日结2月结")
    @CollectionField("settlement_type")
    private Integer settlementType;

    @CollectionField("ico")
    @ApiModelProperty("ico")
    private String ico;

    @CollectionField("location")
    private Point location;

    @CollectionField("job_address")
    @ApiModelProperty("地址")
    private String jobAddress;

    @CollectionField("contact_phone")
    @ApiModelProperty("联系电话")
    private String contactPhone;

    @CollectionField("contact_name")
    @ApiModelProperty("联系人")
    private String contackName;

    @CollectionField(value = "audit_admin_id")
    @ApiModelProperty("审核人")
    private String auditAdminId;

    @CollectionField(value = "audit_admin_name")
    @ApiModelProperty("审核人")
    private String auditAdminName;

    @CollectionField(value = "audit_desc")
    @ApiModelProperty("审核内容")
    private String auditDesc;

    @CollectionField(value = "audit_time")
    @ApiModelProperty("审核时间")
    private Date auditTime;

    @CollectionField("publish_nature")
    @ApiModelProperty("工作属性:1个人发布2公司发布3企业发布")
    private Integer publishNature;

    @CollectionField("publish_user_id")
    @ApiModelProperty("发布人id")
    private String publishUserId;

    @CollectionField("company_id")
    @ApiModelProperty("公司id")
    private String companyId;

    @CollectionField("conpany_name")
    @ApiModelProperty("公司名称")
    private String companyName;

    @CollectionField("individual_id")
    @ApiModelProperty("企业id")
    private String individualId;

    @CollectionField("individual_name")
    @ApiModelProperty("企业名字")
    private String individualName;

    private Date startDate;
    private Date endDate;

    @CollectionField(value = "update_time")
    @ApiModelProperty("更新时间")
    private Date updateTime;


    @CollectionField(value = "oper_time",fill = FieldFill.INSERT_UPDATE)
    @ApiModelProperty(value = "更新时间",hidden = true)
    private Date operTime;

    @CollectionField(value = "oper_id",fill = FieldFill.INSERT_UPDATE)
    @ApiModelProperty(value = "更新人id",hidden = true)
    private Long operId;

    @CollectionField(value = "oper_name",fill = FieldFill.INSERT_UPDATE)
    @ApiModelProperty(value = "更新人",hidden = true)
    private String operName;

    @CollectionField(value = "create_id",fill = FieldFill.INSERT)
    @ApiModelProperty(value = "创建人id",hidden = true)
    private Long createId;

    @CollectionField(value = "create_name",fill = FieldFill.INSERT)
    @ApiModelProperty(value = "创建人",hidden = true)
    private String createName;

    @CollectionField(value = "create_time",fill = FieldFill.INSERT)
    @ApiModelProperty(value = "创建时间",hidden = true)
    private Date createTime;

    @Version
    @CollectionField("version")
    @ApiModelProperty(value = "乐观锁", hidden = true)
    private Integer version;

}
